package com.javaIO.demo;

import java.io.File;

public class Test {
    public static void main(String[] args) {


        /**
         * 正常：D:\SoftDevelopment\Java\file
         * 转义：\\
         */
        File file = new File("D:\\SoftDevelopment\\Java\\file\\demo.txt");
        System.out.println(file);

        File file1 = new File("D:\\SoftDevelopment\\Java\\file", "demo.txt");
        System.out.println(file1);

        File file2 = new File("D:\\SoftDevelopment\\Java\\file");
        File file3 = new File(file2,"demo.txt");
        System.out.println(file3);


    }
}
